Optimal. Leaf size=131 \[ -\frac{\left (a^2 x^2+1\right ) (a x+1)^n (1-a x)^{-n}}{x}-\frac{2 a n (a x+1)^{n-1} (1-a x)^{1-n} \, _2F_1\left (1,1-n;2-n;\frac{1-a x}{a x+1}\right )}{1-n}+\frac{a 2^{-n} n (a x+1)^{n+1} \, _2F_1\left (n+1,n+1;n+2;\frac{1}{2} (a x+1)\right )}{n+1} \]
[Out]
_______________________________________________________________________________________
Rubi [C] time = 0.0668912, antiderivative size = 48, normalized size of antiderivative = 0.37, number of steps used = 1, number of rules used = 1, integrand size = 25, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.04 \[ \frac{a 2^{1-n} (a x+1)^{n+2} F_1\left (n+2;n-1,2;n+3;\frac{1}{2} (a x+1),a x+1\right )}{n+2} \]
Warning: Unable to verify antiderivative.
[In] Int[((1 - a*x)^(1 - n)*(1 + a*x)^(1 + n))/x^2,x]
[Out]
_______________________________________________________________________________________
Rubi in Sympy [A] time = 6.50365, size = 36, normalized size = 0.27 \[ \frac{2^{- n + 1} a \left (a x + 1\right )^{n + 2} \operatorname{appellf_{1}}{\left (n + 2,2,n - 1,n + 3,a x + 1,\frac{a x}{2} + \frac{1}{2} \right )}}{n + 2} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] rubi_integrate((-a*x+1)**(1-n)*(a*x+1)**(1+n)/x**2,x)
[Out]
_______________________________________________________________________________________
Mathematica [C] time = 0.416634, size = 158, normalized size = 1.21 \[ a (a x+1)^n \left (-\frac{2 (1-a x)^{-n} F_1\left (1;n,-n;2;\frac{1}{a x},-\frac{1}{a x}\right )}{2 a x F_1\left (1;n,-n;2;\frac{1}{a x},-\frac{1}{a x}\right )+n \left (F_1\left (2;n,1-n;3;\frac{1}{a x},-\frac{1}{a x}\right )+F_1\left (2;n+1,-n;3;\frac{1}{a x},-\frac{1}{a x}\right )\right )}-\frac{2^{-n} (a x+1) \, _2F_1\left (n,n+1;n+2;\frac{1}{2} (a x+1)\right )}{n+1}\right ) \]
Warning: Unable to verify antiderivative.
[In] Integrate[((1 - a*x)^(1 - n)*(1 + a*x)^(1 + n))/x^2,x]
[Out]
_______________________________________________________________________________________
Maple [F] time = 0.076, size = 0, normalized size = 0. \[ \int{\frac{ \left ( -ax+1 \right ) ^{1-n} \left ( ax+1 \right ) ^{1+n}}{{x}^{2}}}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In] int((-a*x+1)^(1-n)*(a*x+1)^(1+n)/x^2,x)
[Out]
_______________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \[ \int \frac{{\left (a x + 1\right )}^{n + 1}{\left (-a x + 1\right )}^{-n + 1}}{x^{2}}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((a*x + 1)^(n + 1)*(-a*x + 1)^(-n + 1)/x^2,x, algorithm="maxima")
[Out]
_______________________________________________________________________________________
Fricas [F] time = 0., size = 0, normalized size = 0. \[{\rm integral}\left (\frac{{\left (a x + 1\right )}^{n + 1}{\left (-a x + 1\right )}^{-n + 1}}{x^{2}}, x\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((a*x + 1)^(n + 1)*(-a*x + 1)^(-n + 1)/x^2,x, algorithm="fricas")
[Out]
_______________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \[ \text{Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((-a*x+1)**(1-n)*(a*x+1)**(1+n)/x**2,x)
[Out]
_______________________________________________________________________________________
GIAC/XCAS [F] time = 0., size = 0, normalized size = 0. \[ \int \frac{{\left (a x + 1\right )}^{n + 1}{\left (-a x + 1\right )}^{-n + 1}}{x^{2}}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In] integrate((a*x + 1)^(n + 1)*(-a*x + 1)^(-n + 1)/x^2,x, algorithm="giac")
[Out]